<%@ page pageEncoding="utf-8"%>
<%@ include file="/common/taglibs.jsp"%>
 
<title><fmt:message key="serviceSheetList.title"/></title>
<script src="<c:url value='/scripts/common.js'/>"></script>
<meta name="menu" content="ServerProtectMenu"/>
<link rel="stylesheet" type="text/css" media="all"
	href="<c:url value='/styles/css.css'/>" /> 
<html:form action="service" method="post" styleId="serviceSheetForm"> 
 <table width="99%" border="0" cellspacing="0" cellpadding="0" align="center">
      <tr>
        <td align="left" valign="top"><table width="100%" border="0" cellspacing="0" cellpadding="0">
          <tr>
            <td height="30" align="left" background1="images/list_title_bg.jpg"><table width="100%" border="0" cellpadding="0" cellspacing="0">
              <tr>
                <td align="center" valign="bottom">
					 <input type="button" style="margin-right: 5px" class="textarea"
        					onclick="location.href='./service.html?method=edit&flag=add&taskId=<c:out value="${serverProtectForm.requestId}"/>'"
        			value="<fmt:message key="button.add"/>"/>
 
				</td>
              </tr>
            </table></td>
            <td width="6" align="right" valign="top"><%--img src="images/list_title_right.jpg" width="6" height="30" /--%></td>
          </tr>
        </table> 
       
	<table width="100%" border="0" cellspacing="0" cellpadding="0">
							<tr>
							</tr>
                            <tr> 
                              <td width="88%" align="left" valign="top"><table width="100%" border="1" cellpadding="0" cellspacing="0" class="list_bordercolor">
                                  <tr>
                                    <td class="list_font_title"><fmt:message key="serviceSheetForm.recMan"/> </td> 
                                    <td  class="list_font_title"><fmt:message key="serviceSheetForm.serverMan"/></td> 
                                    <td  class="list_font_title"><fmt:message key="serviceSheetForm.sendMan"/></td> 
                                    <td  class="list_font_title"><fmt:message key="serviceSheetForm.restRoom"/></td>
                                    <td  class="list_font_title"><fmt:message key="serviceSheetForm.recPlan"/></td>  
                                    <td  class="list_font_title" width="80" align="center">操作</td>    
                                                
                                                          
                                  </tr>
                                  <c:forEach items="${serviceSheetList}" var="results">
                                  <tr>
	                                  <td class="list_font_area">&nbsp; <c:out value="${results.recMan}"/></td> 
    	                              <td class="list_font_area">&nbsp; <c:out value="${results.serverMan}"/></td> 
        	                          <td class="list_font_area">&nbsp; <c:out value="${results.sendMan}"/></td> 
            	                      <td class="list_font_area">&nbsp; <c:out value="${results.restRoom}"/></td> 
                	                  <td class="list_font_area">&nbsp; <c:out value="${results.recPlan}"/></td> 
                    	              <td class="list_font_area" width="80">&nbsp; 
											  <a href="#" onclick="edit(<c:out value="${results.id}"/>)">修改</a>&nbsp;<a href="#" onclick="onDelete(<c:out value="${results.id}"/>)">删除</a>
										</td> 
                                  </tr>
                               	</c:forEach>
                              </table></td>
                            </tr>
                            
                        </table>     
<input type="hidden" name="requestId" value="<c:out value="${serverProtectForm.requestId}"/>"/>                                      
</html:form>
<script>
	function edit(id){
		location.href='./service.html?method=edit&id='+id;
		
	}

 
	
	function onDelete(id){
		if(confirm('真的要删除该记录吗？')){
			location.href='./service.html?method=delete&taskId=<c:out value="${serverProtectForm.requestId}"/>&id='+id;
		}	
		
	}
	
</script> 


